<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Mouse Middle Button Click</title>
</head>

<body>
    <h1>Click the middle mouse button to see the event</h1>

    <script>
        // 添加鼠标中键点击事件监听器
        document.addEventListener('mousedown', function (event) {
            // 检查是否是鼠标中键
            if (event.button === 1) {
                // 如果是鼠标中键点击事件，打印信息到控制台
                console.log('Middle mouse button clicked!');
            }
        });
    </script>
</body>

</html>